#ifndef STRUCTS_H
#define STRUCTS_H

#include <iostream>

typedef unsigned int uint;

template <class T>
struct Node
{
        Node(T t) : data(t){}
        Node *Next,*Prev;
        T data;
        int n; // № элемента.
};

struct Date
{
    uint d;
    uint m;
    uint y;
    Date() : d(0), m(0), y(0)
    {}
    Date(uint s_d, uint s_m, uint s_y) : d(s_d), m(s_m), y(s_y)
    {}
    friend std::ostream & operator <<(std::ostream & os, const Date & n);

};
std::ostream & operator <<(std::ostream & os, const Date & n)
{
    os<<"Date("<<n.d<<"."<<n.m<<"."<<n.y<<")\n";
    return os;
}

struct group
{
    Date date;
    uint coint;
    double price_bay;
    double price_sale;
    group() : coint(0), price_bay(0), price_sale(0)
    {}
    friend std::ostream & operator <<(std::ostream & os, const group & n);

};
std::ostream & operator <<(std::ostream & os, const group & n)
{
    os<<"group("<<n.date
     <<" price_bay ="<<n.price_bay
     <<" price_sale ="<<n.price_sale<<")\n";
    return os;
}

#endif // STRUCTS_H
